package office.action.business.form;

import office.bo.business.impl.ContractProductDetail;
import platform.common.bo.IIdentifiableObj;
/**
 * 标书对应的产品结构Form
 * @author ZhangYQ
 *
 */
public class ContractProductDetailForm {
	private String id;
	private String productName; //产品名称
	private String productUnit; //产品单位
	private String productType; //产品类型
	private long countNum;      //产品数量
	private double unitPrice;   //产品单价
	private double totalprice;  //产品总价
	private String mark;        //备注
	private String contractId; //对应的合同
	
	public IIdentifiableObj copyPropertiesToBO(IIdentifiableObj newObj) {
		ContractProductDetail bo = (ContractProductDetail)newObj;
		bo.setId(this.id);
		bo.setProductName(productName);
		bo.setProductUnit(productUnit);
		bo.setProductType(productType);
		bo.setCountNum(countNum);
		bo.setUnitPrice(unitPrice);
		bo.setTotalprice(totalprice);
		bo.setMark(mark);
		bo.setContractId(contractId);
		return bo;
	}
	
	public void copyPropertiesFromBO(IIdentifiableObj baseBO) {
		ContractProductDetail bo = (ContractProductDetail)baseBO;
		this.id = bo.getId().toString();
		this.productName = bo.getProductName();
		this.productUnit = bo.getProductUnit();
		this.productType = bo.getProductType();
		this.countNum = bo.getCountNum();
		this.unitPrice = bo.getUnitPrice();
		this.totalprice = bo.getTotalprice();
		this.mark = bo.getMark();
		this.contractId = bo.getContractId();
	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getProductName() {
		return productName;
	}

	public void setProductName(String productName) {
		this.productName = productName;
	}

	public String getProductUnit() {
		return productUnit;
	}

	public void setProductUnit(String productUnit) {
		this.productUnit = productUnit;
	}

	public String getProductType() {
		return productType;
	}

	public void setProductType(String productType) {
		this.productType = productType;
	}

	public long getCountNum() {
		return countNum;
	}

	public void setCountNum(long countNum) {
		this.countNum = countNum;
	}

	public double getUnitPrice() {
		return unitPrice;
	}

	public void setUnitPrice(double unitPrice) {
		this.unitPrice = unitPrice;
	}

	public double getTotalprice() {
		return totalprice;
	}

	public void setTotalprice(double totalprice) {
		this.totalprice = totalprice;
	}

	public String getMark() {
		return mark;
	}

	public void setMark(String mark) {
		this.mark = mark;
	}

	public String getContractId() {
		return contractId;
	}

	public void setContractId(String contractId) {
		this.contractId = contractId;
	}

	
}
